Copyright: Copyright © 1993-1996 Juan M. Aguirregabiria
Citation: Copyright © 1993-1996 Juan M. Aguirregabiria


Sinfo

2.00

Juan M. Aguirregabiria

E-mail: wtpagagj@lg.ehu.es

WWW: http://lcpx07.lc.ehu.es/jma.html

Anonymous ftp: lcpx07.lc.ehu.es

August 1996


Copyright

The program Sinfo.exe, the help files Sinfo.cnt and Sinfo.hlp, the documentation file Sinfo.rtf and all the remaining files in this package are copyrighted:

Copyright © Juan M. Aguirregabiria 1993-1996

All rights reserved

Other brand and product names are trademarks or registered trademarks of their respective holders.

Sinfo is FreeWare; there is no charge for using it and it may be distributed freely so long as the files are kept together and unaltered. You may neither sell nor profit from distribution of Sinfo in any way.

Disclaimer

In no event will the Author be liable to users for any damages, including but not limited to any lost profits, lost savings or other incidental or consequential damages arising out of the use or the inability to use this program, even if the Author has been advised of the possibility of such damages, or for any claim by other party.

Hardware and software requirements

To run this version of Sinfo you need Microsoft Windows 95 and the hardware necessary to run it.


New in this version

New in version 2.00

This is the first full Windows 95 version.

New in version 1.08

New features:

•	An installation program has been added.

•	By using a new menu entry, File/Is Task Manager, it is far easier to install/uninstall Sinfo as Windows task list manager.

•	A new menu entry, File/Restart Windows, lets you close the current Windows session and start a new one.

New in version 1.07

Corrected bugs:

•	The focus is correctly reset while using Capture...

•	The version information resource is now correct.

New in version 1.06

New features:

•	A new menu entry, Manager/Style..., and a new button, Style..., in the Window info dialog allows changing the style bits of any window.

•	Advanced users may use a new entry in the File menu to get rid of warning messages.

•	To avoid misunderstandings, the File/Exit entry is now called File/Exit Sinfo.

•	The line indicating the kind of displayed information appears now above the buttons.

Corrected bugs:

•	The caption of the Move window dialog box displayed an incorrect window handle.

•	Most windows can now be closed by pressing ESC even if there is no Cancel button.

New in version 1.05

New features:

A new entry in the Move... dialog allows changing the caption of any window.

New in version 1.04

New features:

When capturing a screen piece, the display of the box dimensions is now optional.

New in version 1.03

New features:

Using File/Capture one can now send a piece of screen to a new window where it can be seen at different magnifications. From that window you can save the captured rectangle to the clipboard or to a disk file.

New in version 1.02

New features:

A new menu entry, Manager/Move..., and a new button, Move..., in the Windows info dialog, allow moving, resizing and changing the z-order of a window.

Changing the window size is now smother.

A more reliable method is used to identify child and owned windows.

New in version 1.01

Corrected bugs:

In graphics modes with more than 256 colors it did not capture the DIB bitmap. (This bug was due to a bug in an example from Microsoft!)

New features:

A new entry, File/Show cursor, allows recovering a cursor that was lost due to an application crash.

A new entry, File/Exit Windows, allows exiting Windows even if the shell (Program Manager or alternative program) has crashed.


Acknowledgements
Acknowledgments

I would like to thank useful feedback from the following users:

Gary Wingert <garyw@ingres.com>

Gilles Vollant <100144.2636@CompuServe.COM>

Jean-Marc CHALLIER <challier@lucie.irit.fr>

Nils T S <xorax@p117.informatik.uni-Bremen.de>


Other programs from the same author
Other free programs from the same author

Note: For an up-to-date list use your Web browser to visit Author’s site: http://lcpx07.lc.ehu.es/jma.html

Toolbar:

Toolbar is intended to provide some features that I found lacking in the Program Manager and File Manager of the retail Windows 3.1. To start with, while working in File Manager, you can drag an item and drop it over some running programs. But if one of these programs is not running and you drop the item over its icon, the program is not started. Instead, the dropped item is added to the corresponding group of Program manager. Of course, sometimes this is just what you wanted. One could say that the groups in Program manager were meant more for organization of programs than for running them. On the other hand, most programs still lack the ability to accept dropped files and you cannot use with them this drag and drop feature.

Since my screen tends to be cluttered with windows, I also wanted the ability to place (in a permanent and compact way) at a corner of the screen the utilities I used most often. Program Manager groups are nice but big and I do not need to see the names of my favorite utilities: I can easily recognize them by their icons. The utilities should always be at hand - ready to be started by double-clicking them (as in Program Manager) or by dropping an item on them. For instance, this is a nice way to provide the most important facility missing in File Manager: a file viewer.

Toolbar is the answer to these wishes. It provides an alternative to the groups of Program Manager with the following distinctive characteristics:

It can be used either as a substitute for Program Manager (which, in turn, can be run from Toolbar), or as a normal application installed in Program Manager (or in the current shell program).

It is better suited for running programs: there are multiple ways of running programs and advanced settings can be used.

All programs in a toolbar are always visible (as long as the whole window is on the screen). They are held together in a very compact way, to be as unobtrusive as possible. Optionally, you can force a toolbar to be always visible on top of other windows. In order to save space, the title bar can be suppressed (or displayed to have useful information at hand).

Items from File Manager can be dropped on any program installed as a tool. It only needs to be able to accept file names on the command line. Most MS-DOS and Windows programs have this ability. A program can also be started by double-clicking (or single clicking the right button), or by using the ENTER key, or a user selected accelerator key.

You can choose between running an instance of the program for each dropped file, or running a single instance of the program for all of the dropped files.

Programs can be easily added, removed and reordered. The corresponding caption, command line, working directory, icon and other options can be easily changed.

You can implement a full tree of nested toolbars.

You can drag files to and from Toolbar. Program Manager does not allow dragging of  its elements outside of its windows.

Utilities (small utility programs that use a toolbar button as its display window) make Toolbar more compact and extensible. A few are provided with Toolbar: trash can, alarm clock, menu, memory, resources, information and blank icon. Additionally, new utilities can be added by the user (the programmatic interface is fully documented and sample source code is included).

Toolbar supports most of the same user interface as Program Manager.

Toolbar is able to transparently use (and to translate to its own format) group files from Program Manager.

And more!

Filter:

Many DOS utilities and programs share a common characteristic: they are command line programs. Once the command line is supplied, they can run unattended, without any further input from the user.  Often they are “filters”: they receive their input from the standard input, which can be the keyboard, a file redirected with the < operator or another program’s output (through the | pipe operator or using a TEE or Y command). Their output is usually sent to the standard output, which can be the default screen or redirected (with >, >>, |, TEE or Y). For example, every DOS copy comes with SORT and FIND, and there lots of free or shareware programs that emulate well know UNIX filters: AWK, CAT, CMP, CUT, DETAB, DIFF, ENTAB, GREP, LS, MERGE, TAIL, UNIQ, WC, etc.

Of course, one can always open a DOS box to take advantage of these programs from Windows, but often it would be nice to use Windows features: multiple windows, clipboard etc. This is especially true when one is trying a new command and want to see how it works. Often rather than using files, it would be nice to be able to enter the input in a window, run the program and see the output in another window.

Filter is a Windows shell that makes easier entering and trying external DOS (or Windows) programs. The input and output (as well as error log and program file) can be external files (which can be selected from the common dialog box used by most Windows programs) or windows. It is easy to specify the starting directory and other options for the external program and it can be run minimized or even hidden. Different configuration files can be used to take advantage of Filter with different external programs: the settings more appropriate to each program will be remembered  in the next session.

TeX Organizer

TeX Organizer is a simple utility to organize the use under Windows 95 of a group of DOS and/or Windows programs that are to be applied to a single file or to a group or related files. The best example (but not the only) is provided by TeX. Let us assume that you have  a DOS (or even Windows) version of TeX. Typically you have to use:

•	your favorite editor to write and modify (in Plain TeX, LaTeX or another format) the source file, say Sample.TeX,

•	the typesetting program to create the Sample.DVI file,

•	a DVI viewer to check the results,

•	a DVI to PostScript translator to generate the Sample.PS file,

•	a program to send the PostScript file to the printer,

•	a file viewer to check the Sample.log file for errors,

•	a batch file to erase the intermediate Sample.aux, Sample.log and Sample.PS files.

You may also use some utilities to manage references, to draw figures, to view the PostScript output on the screen, etc. Another (simpler) example would be the writing of Windows help files which implies using a RTF editor, the help compiler and, maybe, a program to view the log file containing the errors.

All this mess may be easily handled by using TeX Organizer: You only have to select the main file (Sample.TeX in our example) from a standard open dialog box or by dragging it from the Explorer and then press the buttons corresponding to each or the programs and utilities that you want to apply to the main file or to related files.

Pentominoes

Pentominoes are a generalization of dominoes: all the possible plane configurations formed by five contiguous squares. It is possible to construct all kind of figures containing 60 = 12x5 (or more) squares. Since Solomon W. Golomb introduced them in 1954, it has become a very popular puzzle and thousand of solutions and problems have been published.

Pentominoes may solve any problem which can be selected from an extensible library or directly drawn on the screen by the user.

Touch

Touch is a simple utility to update the different date and time stamps of a single file or of a group of files. You may drag the files from the Explorer and drop them over the Touch window, or select them in a standard dialog box or even indicate them in the command line used to start Touch. You might even install Touch in the Windows\SendTo directory to have the opportunity to send files by using the Send To entry of the context menu that opens when using the right button in a folder or Explorer window.

It is possible to update any combination of the three times Windows 95 saves with each file: creation time, last-access time and modified time. The new time stamp may be the current date and time, or any other you may easily select.

Console utilities for Windows 95

Microsoft has been advertising the new user interface (we could say the Mac-like interface) in Windows 95 and every effort has been made to suggest that Windows 95 no longer runs under DOS, but is a new operating system on is own. Schulman and other authors have conclusively proved that this claim is not completely correct (and also that 16-bit code has still a central role in Windows 95). So DOS is not gone ... BUT THIS IS VERY GOOD NEWS!

To start with, many file maintenance jobs are far easier when using command line utilities and batch files. The “user-friendly” way to do many simple tasks (comparing two directories or copying to the disk the relevant modified files of you current programming task, for instance) is boring and error prone.

On the other hand, UNIX-like filters are still very useful, but the task to provide them a good looking user-friendly interface is probably not worth; after all they will be used only by advanced users that are not afraid of the command line (and even acknowledge its advantages in some cases).

Finally, DOS is still there with Windows 95, but it's a much better DOS! Many previous limitations are gone or lessened, because one may now easily write the so-called “console” mode applications that look like old DOS programs:

•	if they are run form the command line, their output is sent to the DOS box,

•	redirection and pipes are supported as usual.

•	but are true Windows 95 programs with many of the Win32 advantages:

•	long filenames

•	direct access to all available physical and virtual memory (no more  need of those often mutually incompatible DOS extenders).

•	version information

•	threads

•	memory mapped files

•	structured exception handling

•	mouse

•	etc.

I couldn't stand being completely deprived of the command line. After all I do know writing (well, at least in my native language, which obviously is not English). I sometimes think that all these icons and “user-friendly” interfaces are a step back to the caves where icons were used because nobody knew writing. For instance, by using one of the utilities included with this package you can simply write:

  cpy -md . a:\backup

to copy all the files in the current directory (and its subdirectories) that are newer than the same files in the a:\backup directory. How many steps are necessary to do the same thing by using the Explorer? Not to speak about the possibility of errors.

In this package I include new compilation for Windows 95 of some DOS utilities which I have been using from years. I hope you find some of them useful:

Count	Counts characters words, etc.

Cpy	Copy group of files

Cut	Extract some columns, rows, fields or bytes from a file

Detab	Substitutes spaces for Tabs

Entab	Substitutes Tabs for spaces

Filecomp	Compares lines from files

Head	Dumps the first few lines or characters of a file

Paste	Merge lines from different files.

Sort	Sort and merge utility.

Tail	Dumps the last few lines or characters of a file.

Trail	Fixes end of lines.


Index

Using Sinfo

Introduction

Installing and uninstalling Sinfo

Having Sinfo automatically started in the tray

Getting help and information

16 and 32-bit versions of Sinfo

Reference information

Sinfo sheets

Information boxes

Capture window

Error and warning messages

Miscellaneous information

Copyright

New in this version

Acknowledgments

Other free programs from the same author

Suggestions, bugs and help


Introduction

Sinfo is designed to help Windows 95 programmers and advanced users by providing information on many aspects of Windows. It can display full information on current processes (including threads and modules), windows, modules and tasks. There are some advanced (though risky) commands. For instance, it is possible to see (and terminate) hidden processes. You can move, resize, change the z-order, hide (and shown again) windows and make them a top most window (or delete this property). You may also change the name (title or caption) of any window.

The warning messages that you get when trying to do something that could be potentially dangerous may be disabled (though this is not recommended).

You may have Sinfo always at hand in the tray. If you want this, it will be automatically started and located in the tray when a Windows session starts.

The way in which information is obtained and commands are executed is described in this document/help file. To understand fully this information, a fairly knowledge of Windows programming is required (the SDK or equivalent documentation will be helpful).


Installing and uninstalling Sinfo

To install Sinfo, run the Setup program in the distribution disk. It will copy to the desired directory the executable file, Sinfo.exe, the help files Sinfo.cnt and Sinfo.hlp and the documentation file: Sinfo.rtf. (See also Having Sinfo automatically started in the tray.)

To uninstall Sinfo,

1.	Use Add or remove programs from the Control panel.

2.	If necessary, remove any remaining files in the installation directory.


Having Sinfo automatically started in the tray

If you check in the Put icon in tray button in the Options sheet, Sinfo will be always available, even after you close it or start a new Window session, in the tray.

If you left click on the Sinfo tray icon, the program main window will open. If, you right click the following popup menu appears:

Command	Action
Open	Open Sinfo’s main window
Quit	Exit Sinfo and remove it from the tray (but it will be there when Sinfo or Windows start again)
About Sinfo	Open the information dialog box
Help	Open the help contents page
If you run Sinfo with a command line in the form

[path]sinfo.exe t

or indicate a t (or T) option in the shortcut properties box, the program will be initially located in the tray and its main window will not be displayed until you click on the tray icon or use the menu. The only difference with the use of the Put icon in tray option is that when you close the main window the program will exit at its icon removed from the tray.


Getting help
Getting help and information

Sinfo is a full Windows 95 program and, in consequence, its dialog boxes include context-sensitive help. Since you may easily get many new windows while using Sinfo, its dialog boxes must include the Minimize button/menu entry. Unfortunately, this precludes the display of the question-mark button that usually indicates context-sensitive help. But, it is there! Use one of the following procedures:

•	Right click over any button or control to get the familiar “What’s This?” menu from which the corresponding help topic is open. Remember that edit boxes have their own context-sensitive menu. Right click on their label to get information on an edit box.

•	Press F1 to get help on the last active control or button. You may get surprising results if you do not remember which was the last active control, which can be set by clicking on it and making sure that the mouse button is released outside the button and that the option has not been changed.


16 and 32-bit versions of Sinfo

This is the 32-bit version of Sinfo for Windows 95. But there exist a 16-bit edition for Windows 3.1+ that you might want to get (or retain), because these programs are complementary, at least to some extent, and there are things that are possible only from 16-bit programs (at least until I fully understand the thunk compiler). Some of the 16-bit edition features do not work under Windows 95 (for instance it is not possible to examine non-system classes, or to pick a window with the cursor), but it has some possibilities to dump memory zones that are lacking in this 32-bit version.

You may get the last versions of the 16 and 32-bit editions from Author’s site: http://lcpx07.lc.ehu.es/jma.html


Sinfo sheets

Sinfo’s main window (a dialog box) has the following sheets, which are accessed by clicking the corresponding tab:

Sheet	Contains
Options	General options, commands to close the Windows session and information boxes, etc.
Processes	Display information on the current processes and their threads and modules.
Windows	Display the full window tree.
Task Manager	Display and control the active tasks.
Capture Screen	Capture the contents of other windows or screen pieces.
In the bottom line the following buttons appear:

Dismiss	Close Sinfo. It will remain in the tray if Put icon in tray is active. To completely exit the program with this option enabled, right click on the tray icon and select the Quit option in the popup menu.
Refresh	Refresh the contents of this window.
Help	Get help on this window


Press this button to accept the changes you have made and close this window. Sinfo will try to apply the new attributes.


Press this button to close this window with no further action. If this is the main dialog box after closing it will remain in the tray if Put icon in tray is active. To completely exit the program with this option enabled, right click on the tray icon and select the Quit option in the popup menu.


Press this button to refresh the contents of this window.


Press this button to get help on this window.


Press this button to get help on this dialog box.


Options sheet

In this sheet you may get general options, commands to close the Windows session and information boxes, etc. The available options are the following:

General options
Put icon in tray…	Check in this option to have Sinfo installed in the tray. It will be there at hand even if you close the main window or restart the Windows session. To remove it from the tray during the current Window session, use the Quit entry of the popup menu which opens when right clicking in the tray icon. Unless you clear this check box, Sinfo will be installed again in the tray when the program is run (from the Explorer, for instance) or Windows restart.
Skip all warning messages…	Check in this option to avoid getting a warning message each time you are about to do something potentially dangerous. This should be used only by advanced users at their own risk!
Skip children	If this option is checked in you will not get child windows while using the cursor to pick a window. This mode is entered from the Capture sheet.
Quit session
Exit Windows	Use this button to exit the current Windows session. (ExitWindowsEx(EWX_SHUTDOWN) is used). See Force exit with no warning to add the EWX_FORCE flag and terminate non responding applications without warning.
Restart Windows	Press this button to close the current Windows session and start a new one. (ExitWindowsEx(EWX_REBOOT) is used). See Force exit with no warning to add the EWX_FORCE flag and terminate non responding applications without warning.
Log off current user	Press this button to log out the current user profile. (ExitWindowsEx(EWX_LOGOFF) is used). See Force exit with no warning to add the EWX_FORCE flag and terminate non responding applications without warning.
Force exit…	Use this option to terminate non responding applications without warning when using Exit Windows, Restart Windows or Log of current user. This adds the EWX_FORCE flag to the ExitWindowsEx call.
Other commands
Close information boxes	Press this button to close all Sinfo information boxes. Useful to clear the screen.
About Sinfo…	This opens dialog box (also called the ego box).with displays some version and copyright information.


General options to customize Sinfo.


Check in this option to have Sinfo installed in the tray. It will be there at hand even if you close the main window or restart the Windows session. To remove it from the tray during the current Window session, use the Quit entry of the popup menu which opens when right clicking in the tray icon. Unless you clear this check box, Sinfo will be installed again in the tray when the program is run (from the Explorer, for instance) or Windows restart.


Check in this option to avoid getting a warning message each time you are about to do something potentially dangerous. This should be used only by advanced users at their own risk!


If this option is checked in you will not get child windows while using the cursor to pick a window. This mode is entered from the Capture sheet.


Buttons to quit or restart Windows.


Use this button to exit the current Windows session. (ExitWindowsEx(EWX_SHUTDOWN) is used). See Force exit with no warning to add the EWX_FORCE flag and terminate non responding applications without warning.


Press this button to close the current Windows session and start a new one. (ExitWindowsEx(EWX_REBOOT) is used). See Force exit with no warning to add the EWX_FORCE flag and terminate non responding applications without warning.


Press this button to log out the current user profile. (ExitWindowsEx(EWX_LOGOFF) is used). See Force exit with no warning to add the EWX_FORCE flag and terminate non responding applications without warning.


Use this option to terminate non responding applications without warning when using Exit Windows, Restart Windows or Log of current user. This adds the EWX_FORCE flag to the ExitWindowsEx call.


Buttons to close auxiliary windows and to show information on Windows.


Press this button to close all Sinfo information boxes. Useful to clear the screen.


This opens dialog box (also called the ego box).with displays some version and copyright information.


Processes sheet

This sheet displays information on the current processes and their threads and modules.

A first list shows the processes currently running in the system with some information for each process. More information can be get by pressing the View process button.

In a second list below all the threads  or modules corresponding to the process currently selected are displayed. You switch between threads and modules by using the Show threads/Show modules button.

There are also the following buttons

Show threads / Show modules	Switch the display of threads and modules.
View process	Display the Process information dialog box.
View module	Display the Module information dialog box.
Kill process	Use OpenProcess(PROCESS_TERMINATE,FALSE,dwId) to terminate the selected process. Use at your own risk!


This list shows the processes currently running in the system with some information on each process. More information can be get by pressing the View process button.


This list shows the threads of the process selected in the list above. Use the Show modules button to display information on process modules.


This list shows the modules of the process selected in the list above. Use the Show threads button to display information on process threads.


Switch the display of threads and modules in the box below.


Display the Process information dialog box.


Display the Module information dialog box.


Use OpenProcess(PROCESS_TERMINATE,FALSE,dwId) to terminate the selected process. Use at your own risk!


Windows sheet

This sheet displays the full window tree. Branches contain child windows and are displayed and collapsed by using + and - signs (or double clicking on an item). If the window has a caption it is displayed between double quotes, otherwise  the process name is displayed between parentheses. If Show class is checked in he class name will be displayed after the caption. You may select a window in this tree and then one of the following buttons:

Close	Close the window with PostMessage(hwnd,WM_CLOSE,0,0);
Destroy	Destroy the window with DestroyWindow(hwnd);
Minimize / Restore	Change the display size of the window.
Hide / Show	Change the visibility attribute.
Top most / Not top most	Switch On/Off the property of being displayed above the non top most windows.
Window	Show the Window information dialog box for the current window.
Class	Show the Class information dialog box for the current window.
Process	Show the Process information dialog box for the current window
Module	Show the Module information dialog box for the current window.
Alternatively, you may use the Pick button. Sinfo’s window will be placed under all the remaining windows. You may move the mouse pointer and the window below will have a distinctive frame. When the desired window is under the cursor left click to open the corresponding Window information dialog box or press ESC to abandon. If the Skip children while seeking for window option in the Options sheet is checked in, only windows  with no parent will be selected.


The full window tree. Branches contain child windows and are displayed and collapsed by using + and - signs (or double clicking on an item). If the window has a caption it is displayed between double quotes, otherwise  the process name is displayed between parentheses. If Show class is checked in he class name will be displayed after the caption. You may select a window in this tree or by using the Pick button below.


If this is checked in, the class name will be displayed after the caption.


Close the selected window with PostMessage(hwnd,WM_CLOSE,0,0);


Destroy the selected window with DestroyWindow(hwnd);


Change the display size of the selected window.


Change the visibility attribute of the selected window.


Switch On/Off the property of being displayed above the non top most windows.


Show the Window information dialog box for the current window.


Show the Class information dialog box for the current window.


Show the Process information dialog box for the current window.


Show the Module information dialog box for the current window.


Sinfo’s window will be placed under all the remaining windows. You may move the mouse pointer and the window below will have a distinctive frame. When the desired window is under the cursor left click to open the corresponding Window information dialog box or press ESC to abandon. If the Skip children while seeking for window option in the Options sheet is checked in, only windows  with no parent will be selected.


Task Manager sheet

This sheet lets you see and control the active tasks. It is similar to the task list but contains no Start button and includes any non-child window, even if it has no caption. If the Hidden option is checked in, hidden windows are also included in the list. You may switch to a task by double clicking on its line. Sinfo will disappear if Close on switch is active. Alternatively you may select one of the task windows and use any of the following buttons:

Switch to	Activate the selected window. Sinfo will disappear if Close on switch is active.
Window	Show the Window information dialog box for the current window.
Cascade	Arrange all opened windows in an overlapped fashion.
Tile horizontal	Arrange all opened windows in an overlapped fashion. Windows will be as large as possible.
Tile vertical	Arrange all opened windows in an overlapped fashion. Windows will be as tall as possible.
Minimize all	Minimize all windows.


This list lets you see and control the active tasks. It is similar to the task list but contains no Start button and includes any non-child window, even if it has no caption. If the Hidden option is checked in, hidden windows are also included in the list.


If this options is checked in, the task list will include hidden windows.


If this options is checked in, Sinfo will disappear when you switch to another task by double clicking on it or selecting Switch to.


Activate the selected window. Sinfo will disappear if Close on switch is active.


Arrange all opened windows in an overlapped fashion.


Arrange all opened windows in an overlapped fashion. Windows will be as large as possible.


Arrange all opened windows in an overlapped fashion. Windows will be as tall as possible.


Minimize all windows.


Show the Window information dialog box for the current window.


Capture Screen sheet

Use this sheet to capture the contents of other windows or screen pieces.

Screen area to capture	This lets you specify a screen rectangle to be captured:
Select with mouse	You will select two opposite corners of the rectangle by using the mouse.
Show dimensions	If this entry is checked the starting and end points of the rectangle will be automatically displayed.
Rectangle	You select the dimensions of the rectangle in Dimensions which has two entries:
Width	The rectangle width (in pixels).
Height	The rectangle height (in pixels).
Icon	A rectangle with the dimensions of a icon will be captured.
Small icon	A rectangle with the dimensions of a small icon will be captured.
Client area of a window	You select with the mouse the window whose client area is to be captured. Child windows can be selected only if Show children is enabled.
Entire window	You select the window to be captured. Child windows can be selected only if Show children is enabled. The whole window (including caption, etc.) will be captured.
Full screen	The whole screen will be captured.
Send capture to	Select here where should be stored the captured window:
New window	A new Capture window will open to show the window.
Clipboard	The device dependent bitmap, the device independent bitmap and the palette will be sent to the clipboard.
File	The device independent bitmap will be stored in the .BMP file you select.
Finally there is a big button which displays the instructions to actually start the capture process.


Select here the screen piece you want to capture.


Use the mouse pointer to select two opposite corners the screen piece.


Capture a screen piece of prescribed dimensions.


Capture a screen piece with the dimensions of a regular icon.


Capture a screen piece with the dimensions of a small icon.


Capture the client rectangle of a window. Child windows may be individually captured only if Skip children while seeking for window is not selected in the Options sheet.


Capture a whole window. Child windows may be individually captured only if Skip children while seeking for window is not selected in the Options sheet.


Capture all the current screen contents.


Select here the prescribed dimensions for the capture rectangle.


The prescribed width for the capture rectangle.


The prescribed height for the capture rectangle.


The prescribed width for the capture rectangle.


The prescribed height for the capture rectangle.


Select here where should be sent to the captured rectangle.


Show the captured rectangle in a new window.


Copy the captured rectangle to the clipboard.


Send the captured rectangle to a bitmap file .


Show the dimensions of the capture rectangle while you are selecting it with the mouse pointer.


Follow the instructions in this button to start the capture process.


Dialog boxes
Information boxes

The following dialog boxes may appear in Sinfo:

Process information

Module information

Window information

Class information

About Sinfo...	(version and Copyright information)

Capture screen

Move window

Style of window


Task info dialog box
Process information dialog box

This dialog box appears when the View process button from the Process sheet or the Process button from the Window sheet or a Window information dialog box is used. (You can also double click directly on a process from the corresponding list in the Process sheet.) Most of the information is obtained from a PROCESSENTRY32 struct pe provided by the ToolHelp32 functions. The following controls are available:

Name	Process name (part of the pe.szExeFile).
Identifier	Process . handle (pe.th32ProcessID).
Parent	Handle of the parent process (pe.th32ParentProcessID).
Usage count	Count from pe.cntUsage.
Base priority	Priority in pe.PcPriClassBase.
Executable file	File specification in pe.szExeFile.
Priority class	Priority class from OpenProcess(PROCESS_ALL_ACCESS,FALSE,pe.th32ProcessID).
Dismiss	Close the dialog.
Module	Open the corresponding Module information dialog box.
Terminate	Kill the process by using OpenProcess(PROCESS_TERMINATE,FALSE,pe.th32ProcessID).
Help	Open this help topic.
The process icon is also visible in the dialog box.


Process name (part of the pe.szExeFile).


Priority class from OpenProcess(PROCESS_ALL_ACCESS,…


Priority class from OpenProcess(PROCESS_ALL_ACCESS,…


Priority class from OpenProcess(PROCESS_ALL_ACCESS,…


Priority class from OpenProcess(PROCESS_ALL_ACCESS,…


Priority class from OpenProcess(PROCESS_ALL_ACCESS,…


Process . handle (pe.th32ProcessID).

Handle of the parent process (pe.th32ParentProcessID).


Count from pe.cntUsage.


Priority in pe.PcPriClassBase.


File specification in pe.szExeFile.


Open the corresponding Module information dialog box.


Kill the process by using OpenProcess(PROCESS_TERMINATE,…


Process icon.


Module info dialog box
Module information dialog box

This dialog box appears when the View module button from the Process sheet or the Module button from the Window sheet or a Window information or Process information dialog box is used. (You can also double click directly on a module from the corresponding list in the Process sheet.) Most of the information is obtained from a MODULEENTRY32 struct me provided by the ToolHelp32 functions. The following controls are available:

Name	Module name.
Process	Module handle.(me.h32ProcessID).
Usage count	The reference count from me.GlblcntUsage.
Type	Indicates if it is a 16-bit or 32-bit application.
Size	Module size from me.modBaseSize.
Executable file	The corresponding executable file specification from me.szExePath.
Dismiss	Close the dialog.
Help	Open this help topic.
The (regular and small) module icons are also visible in the dialog box.


Module name.


Module handle.(me.h32ProcessID).


The reference count from me.GlblcntUsage.


Indicates if it is a 16-bit or 32-bit application.


Module size from me.modBaseSize.


The corresponding executable file specification from me.szExePath.


Module regular icon.


Module small icon


Window dialog box
Window information dialog box

This dialog box appears when the Window button from the Process or Task Manager sheets is used. The following controls are available:

Title	The window caption as returned by GetWindowText.
Window handle	The window handle.
Parent	The parent window handle as returned by GetParent.
Class name	The window class name as returned by GetClassName.
Id / Menu	The menu or child identifier as obtained from GetWindowID.
(left,top)	The window left and top coordinates from GetWindowRect.
(rigth,bottom)	The window right and bottom coordinates from GetWindowRect.
Width	The client rectangle width from GetClientRect.
Height	The client rectangle height from GetClientRect.
Style: hhhhhhhh (Extra: hhhhhhhh)	Window and extra styles from GetWindowStyle and GetWindowExStyle.  (In hexadecimal and by using the corresponding #defines.)
Properties	Property handles and strings in the form hhhhhhhh=string from EnumProps.

The following buttons are also available:

Dismiss	Close the dialog.
Help	Open this help topic.
Switch to	Make this the active window.
Close	Close the window by sending a WM_CLOSE message.
Destroy	Close the window by sending a WM_DESTROY message.
Minimize/Restore	the window.
Hide/Show	the window.
Top most/Not  top most	Set/reset this flag.
Move...	Open the Move window dialog box.
Style...	Open the Style of window dialog box.
Class...	Open the Class information dialog box.
Process...	Open the Process information dialog box.
Module...	Open the Module information dialog box.


The window caption as returned by GetWindowText.


The window handle.


The parent window handle as returned by GetParent.


The window class name as returned by GetClassName.


The menu or child identifier as obtained from GetWindowID.


The window left and top coordinates from GetWindowRect


The window right and bottom coordinates from GetWindowRect


The client rectangle width from GetClientRect.


The client rectangle height from GetClientRect.


Hexadecimal window and extra styles from GetWindowStyle and GetWindowExStyle.


#defines for the window and extra styles from GetWindowStyle and GetWindowExStyle.


Property handles and strings in the form hhhhhhhh=string from EnumProps.


Make this the active window.


Close the window by sending a WM_CLOSE message.


Close the window by sending a WM_DESTROY message.


Minimize or restore the window.


Hide or make visible the window.


Set/reset the flag indicating that the window should appear above the remaining no top most windows.


Open the Move window dialog box.


Open the Style of window dialog box.


Open the corresponding Class window dialog box.


Open the corresponding Process window dialog box.


Open the corresponding Module window dialog box.


Class info dialog box
Class information dialog box

This dialog box appears when the Class button from the Window sheet or a Window information dialog box is used. Most of the information is obtained fro a WNDCLASSEX struc wc which has been reconstructed by means of appropriate GetClassLong calls. The following controls are available:

Class name	Class name from a GetClassName.
Process name	Owner process name.
Module instance	Owner module handle in wc.hInstance.
Menu	Class menu from wc.lpszMenuName.
Class extra bytes	Class extra bytes from wc.cbClsExtra.
Window extra bytes	Window extra bytes from wc.cbWndExtra.
Main icon (hhhhhhhh)	Class main icon handle (00000000 if none).
Small icon (hhhhhhhh)	Class small icon handle (00000000 if none).
Cursor (hhhhhhhh)	Class cursor handle (00000000 if none).
Brush (hhhhhhhh)	Class background brush handle (00000000 if none) or #define value.
Style	Class style is displayed by means of the corresponding #defines.
Dismiss	Close the dialog.
Help	Open this help topic.


Class name from a GetClassName.


Owner process name.


Owner module handle in wc.hInstance.


Class menu from wc.lpszMenuName.


Class extra bytes from wc.cbClsExtra.


Window extra bytes from wc.cbWndExtra.


Class main icon


Class main icon handle (00000000 if none).


Class small icon.


Class small icon handle (00000000 if none).


Class cursor.


Class cursor handle (00000000 if none).


Class background brush.


Class background brush handle (00000000 if none) or #define value.


Class style is displayed by means of the corresponding #defines.


Class style is displayed by means of the corresponding #defines.


Move window dialog box

This dialog box appears when the Move button of the Window information dialog box is used. The window whose  handle appears in the caption may have its own caption changed and it may be moved, sized or ordered by means of appropriate SetWindowText and  SetWindowPos calls.The following entries are available:

Change	If this box is checked, the window will be have its caption set to the string entered in the next edit box.
Title	New window caption.
Move	If this box is checked, the window will be moved to the position (relative to the parent window, if any) entered in the following two entries.
Left	The new left position of the window.
Top	The new top position of the window.
Size	If this box is checked, the window will be resized according to the following two entries.
Width	The new window width.
Height	The new window height.
Order	If this box is checked, the window will be placed in the Z-order according to the following entry.
After	The window that will precede the current one. This parameter must be a window handle or one of the following values:
	0 Places the window at the top of the Z-order.
	1 Places the window at the bottom of the Z-order. If  the window was  a topmost window, it loses this status.
	-1 (FFFFFFFF) Places the window above all  windows and gains the topmost status.
	-2 (FFFFFFFE) Repositions the window to the top of all non-topmost windows (that is, behind all topmost windows). This flag has no effect if the window is already a non-topmost window.
Redraw	If this flag is not set, the window will not be redrawn and strange things may happen.
Activate	The window is activated and moved to the top of either the topmost or non-topmost group.
Draw frame	Draws a frame (defined in the window's class description) around the window.


If this box is checked, the window will be have its caption set to the string entered in the next edit box.


New window caption.


New window caption.


If this box is checked, the window will be moved to the position (relative to the parent window, if any) entered in the following two entries.


The new left position of the window.


The new left position of the window.


The new top position of the window.


The new top position of the window.


If this box is checked, the window will be resized according to the following two entries.


The new window width.


The new window width.


The new window height.


The new window height.


If this box is checked, the window will be placed in the Z-order according to the following entry.


The window that will precede the current one. This parameter must be a window handle or one of the following values:

0	Places the window at the top of the Z-order.

1	Places the window at the bottom of the Z-order. If  the window was  a topmost window, it loses this status.

-1 (FFFFFFFF)	Places the window above all  windows and gains the topmost status.

-2 (FFFFFFFE)	Repositions the window to the top of all non-topmost windows (that is, behind all topmost windows). This flag has no effect if the window is already a non-topmost window.


The window that will precede the current one. This parameter must be a window handle or one of the following values:

0	Places the window at the top of the Z-order.

1	Places the window at the bottom of the Z-order. If  the window was  a topmost window, it loses this status.

-1 (FFFFFFFF)	Places the window above all  windows and gains the topmost status.

-2 (FFFFFFFE)	Repositions the window to the top of all non-topmost windows (that is, behind all topmost windows). This flag has no effect if the window is already a non-topmost window.


If this flag is not set, the window will not be redrawn and strange things may happen.


The window is activated and moved to the top of either the topmost or non-topmost group.


Draws a frame (defined in the window's class description) around the window.


Style of window dialog box

This dialog box appears when the Style button of the Window information dialog box is used. The style and extended style double words for the window whose  handle appears in the caption are displayed in the Style and Extra style edit boxes. Below, several check boxes show individual style bits, including their documented names, if any.


Style double word for the window whose handle is displayed in the caption.


Extra style double word for the window whose handle is displayed in the caption.


Individual bit style (including its documented name, if any) for the window whose handle is displayed in the caption.


Individual extra bit style (including its documented name, if any) for the window whose handle is displayed in the caption.

more information on this common dialog.


Capture window

This kind of window will open to displays at different magnification scales, the captured piece of the screen if Send capture to/New window in the Capture screen sheet is selected.

The window has a menu with the following entries:

Menu	Entry	Meaning
File	Save	Send the captured piece of screen to a .BMP file.
	Copy to the clipboard	Copy the displayed bitmap to the clipboard
	Close	Close the window
Scale	x1	Set the magnification
	x2
	x4
	x8
	x16
	x32
Help	Help	Show this help screen


Error and warning messages

Apart from the self-explanatory error messages provided by Windows, Sinfo might display the following messages:

Window no longer exists	The window has been destroyed and is no longer available.

The following warning messages are disabled if the Skip all warning messages option in the Options sheet is checked in. Be careful, if you ignore them unexpected consequences might arise, including loss of information and system hangs.

•	Do you really want to change the process priority class?

•	Do you really want to log off?

•	Do you really want to modify a child window?

•	Do you really want to modify the desktop window?

•	Do you really want to restart the system?

•	Do you really want to shut down the system?

•	Do you really want to end the process?


Suggestions, bugs and help

The Author would highly appreciate receiving information about any bug or problem found in the program. Suggestions to improve Sinfo in future versions are also welcome.

I would especially appreciate help to correct the English version of the help and documentation files.

Write to:

Juan M. Aguirregabiria

E-mail: wtpagagj@lg.ehu.es

WWW: http://lcpx07.lc.ehu.es/jma.html

Anonymous ftp: lcpx07.lc.ehu.es


Glossary


A handle is an hexadecimal number (from 00000000 to FFFFFFFF) identifying a module, a task, a window, etc.


An number preceded by # to indicate a resource loaded by using MAKEINTRESOURCE.


To decide if a window is a child or if it is owned, Sinfo now uses the following check:

BOOL IsAChild(HWND hwnd)

{

  return GetWindow(hwnd,GW_OWNER) ||

         GetParent(hwnd) ||

         (GetWindowStyle(hwnd) & WS_CHILD);

}


The tray is the rightmost, or bottom, part of the task bar where the clock and other useful icons are permanently displayed.


Selected one of the different sheets in the main dialog by clicking on the corresponding tab.